<template>
  <div>
    <h2 class="title">{{message}}</h2>
    <button @click="btnClick">按钮</button>
    <a href="#">点击</a>
    <Cpn></Cpn>
  </div>
</template>

<script>
  import Cpn from './Cpn'
  export default {
    name: "App",
    components:{Cpn},
    data() {
      return {
        message: 'hello Vue',
        name: 'no hello'
      }
    },
    methods: {
      btnClick() {
        this.message = this.name
      }
    }
  }
</script>

<style scoped>
  .title {
    color: goldenrod;
  }
</style>